<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://ckeditor.com" prefix="ckeditor" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--
Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
-->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>HTML Compliant Output &mdash; CKEditor Sample</title>
	<meta content="text/html; charset=utf-8" http-equiv="content-type" />
	<script type="text/javascript" src="ckeditor/ckeditor.js"></script>
	<script src="sample.js" type="text/javascript"></script>
	<link href="sample.css" rel="stylesheet" type="text/css" />
</head>
<body>
	
	
	<form action="postdata.jsp?currPage=1" method="post">
		<p>
			<textarea cols="80" id="content" name="fileUpload"></textarea> 
		</p>
		<p>
			<input type="submit" value="Submit"/>
		</p>
	</form>
	<!-- 
	<form action="postdata.jsp" method="post">
		<p>
			<label for="editor1">
				Editor 1:</label>
			<textarea cols="80" id="editor1" name="editor1" rows="10">&lt;p&gt;This is some &lt;strong&gt;sample text&lt;/strong&gt;. You are using &lt;a href="http://ckeditor.com/"&gt;CKEditor&lt;/a&gt;.&lt;/p&gt;</textarea>
		</p>
		<p>
			<input type="submit" value="Submit"/>
		</p>
	</form>
	<ckeditor:replace replace="editor1" basePath="../ckeditor/" /> 
	-->
<input type="button" value="Get Data" onclick="getContent()">
<script type="text/javascript">  

      CKEDITOR.replace('content');   //content为textarea的id
      
      function getContent() {
      	alert(getBrowserType()); 
      }
      
      //获取浏览器类型 IE/FIREFOX
      function getBrowserType(){   
		var oType = "";   
	    if(navigator.userAgent.indexOf("MSIE")!=-1){   
	        oType="IE";   
	    }else if(navigator.userAgent.indexOf("Firefox")!=-1){   
	        oType="FIREFOX";   
	    }   
	    return oType;   
	  }
      
</script>

	
</body>
</html>
